package com.jcfk.system.domain.po;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.Version;
import com.jcfk.common.business.entity.BaseEntity;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 角色
 */
@Data
@TableName("sys_role")
public class SysRole extends BaseEntity {

    private static final long serialVersionUID = 1L;
    /**
     * 版本号
     */
    @Version
    @TableField(value = "version")
    private Long version;

    /**
     * 角色名称
     */
    @TableField(value = "role_name")
    private String roleName = "";

    /**
     * 删除标志
     */
    @TableField(value = "deleted")
    private Integer deleted;

    /**
     * 启用标志
     */
    @TableField(value = "enabled")
    private Integer enabled;

    /**
     * 备注
     */
    @NotBlank()
    @NotNull()
    @TableField(value = "remarks")
    private String remarks = "";

    /**
     * 创建人姓名
     */
    @TableField(value = "created_user_name")
    private String createdUserName;

    /**
     * 最近一次更新人姓名
     */
    @TableField(value = "last_updated_user_name")
    private String lastUpdatedUserName;
}
